﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true" CodeFile="PromoAnalysis.aspx.cs" Inherits="PromoAnalysis" %>

<%@ Register assembly="System.Web.DataVisualization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" namespace="System.Web.UI.DataVisualization.Charting" tagprefix="asp" %>

<%@ Register assembly="AjaxControlToolkit" namespace="AjaxControlToolkit" tagprefix="asp" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" Runat="Server">
    <style type="text/css">
        .imagerate
        {
            border-width:0px;
            margin:0px;
            padding:0px;
            width:15px;
            height:18px;
            background-image:url("images/rate.jpg");
        }
        .imageblank
        {
            border-width:0px;
            margin:0px;
            padding:0px;
            width:15px;
            height:18px;
            background-image:url("images/blank.gif");
        }
        .imagestart
        {
            border-width:0px;
            margin:0px;
            padding:0px;
            width:15px;
            height:18px;
            background-image:url("images/blank.gif");
        }
        .style6
        {
            color: #0033CC;
            font-size: x-large;
        }
    </style>

</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" Runat="Server">
    <span class="style6"><strong>Analyse your usage</strong></span>
    <br />
<br />
    <asp:Button ID="btnProcess" runat="server" onclick="btnProcess_Click" 
        Text="Recommend Promotion" />
    <br />
    <strong>
    <br />
    Here is summary of your calling usage</strong><br />
    <br />
    <asp:TabContainer ID="tabsAnalyse" runat="server" ActiveTabIndex="0">
        <asp:TabPanel runat="server" Width="100%" HeaderText="Overall" ID="tabOverall">
        <ContentTemplate><asp:Panel ID="Panel1" runat="server"><asp:Label ID="Label11" runat="server" Text="Call Duration" Font-Bold="True"></asp:Label><br /><br /><asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" 
            CellPadding="4" ForeColor="#333333" GridLines="None" Width="100%"><AlternatingRowStyle BackColor="White" ForeColor="#284775" /><Columns><asp:TemplateField HeaderText="All Calling"><ItemTemplate><asp:Label ID="Label1" runat="server" Text='<%# Bind("ID") %>'></asp:Label></ItemTemplate><HeaderStyle Width="200px" /></asp:TemplateField><asp:TemplateField 
                    HeaderImageUrl="~/images/timehead.jpg"><ItemTemplate><div 
                        style="width: 380px; height: 18px; margin: 0 20px 0 20px; background-image: url('http://localhost:49460/promo/images/scale.gif');"><asp:Literal 
                        ID="Literal1" runat="server" Text='<%# Bind("Graph") %>'></asp:Literal></div></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderText="% of total usages"><ItemTemplate><asp:Label ID="Label2" runat="server" Text='<%# Bind("Mins") %>'></asp:Label></ItemTemplate><HeaderStyle HorizontalAlign="Right" /><ItemStyle HorizontalAlign="Right" /></asp:TemplateField><asp:TemplateField HeaderText="Score" Visible="False"><ItemTemplate><asp:Label ID="Label3" runat="server" Text='<%# Bind("Score") %>'></asp:Label></ItemTemplate></asp:TemplateField><asp:TemplateField><HeaderStyle 
                    Width="10px"></HeaderStyle></asp:TemplateField></Columns><EditRowStyle BackColor="#999999" /><FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" /><HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" /><PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" /><RowStyle BackColor="#F7F6F3" ForeColor="#333333" /><SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" /><SortedAscendingCellStyle BackColor="#E9E7E2" /><SortedAscendingHeaderStyle BackColor="#506C8C" /><SortedDescendingCellStyle BackColor="#FFFDF8" /><SortedDescendingHeaderStyle BackColor="#6F8DAE" /></asp:GridView><br /><br /><br /><asp:Label ID="Label12" runat="server" Font-Bold="True" Text="Call Frequency"></asp:Label><br /><br /><asp:GridView ID="GridView4" runat="server" AutoGenerateColumns="False" 
            CellPadding="4" ForeColor="#333333" GridLines="None" Width="100%"><AlternatingRowStyle BackColor="White" ForeColor="#284775" /><Columns><asp:TemplateField HeaderText="All Calling"><ItemTemplate><asp:Label ID="Label17" runat="server" Text='<%# Bind("ID") %>'></asp:Label></ItemTemplate><HeaderStyle Width="200px" /></asp:TemplateField><asp:TemplateField 
                        HeaderImageUrl="~/images/timehead.jpg"><ItemTemplate><div 
                            style="width: 380px; height: 18px; margin: 0 20px 0 20px; background-image: url('http://localhost:49460/promo/images/scale.gif');"><asp:Literal 
                            ID="Literal1" runat="server" Text='<%# Bind("Graph") %>'></asp:Literal></div></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderText="% of total usages"><ItemTemplate><asp:Label ID="Label18" runat="server" Text='<%# Bind("Mins") %>'></asp:Label></ItemTemplate><HeaderStyle HorizontalAlign="Right" /><ItemStyle HorizontalAlign="Right" /></asp:TemplateField><asp:TemplateField HeaderText="Score" Visible="False"><ItemTemplate><asp:Label ID="Label19" runat="server" Text='<%# Bind("Score") %>'></asp:Label></ItemTemplate></asp:TemplateField><asp:TemplateField><HeaderStyle 
                        Width="10px"></HeaderStyle></asp:TemplateField></Columns><EditRowStyle BackColor="#999999" /><FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" /><HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" /><PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" /><RowStyle BackColor="#F7F6F3" ForeColor="#333333" /><SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" /><SortedAscendingCellStyle BackColor="#E9E7E2" /><SortedAscendingHeaderStyle BackColor="#506C8C" /><SortedDescendingCellStyle BackColor="#FFFDF8" /><SortedDescendingHeaderStyle BackColor="#6F8DAE" /></asp:GridView></asp:Panel></ContentTemplate>
        </asp:TabPanel>
        <asp:TabPanel runat="server" Width="100%"  HeaderText="By Operator" ID="tabOperator">
        <ContentTemplate><asp:Panel ID="Panel2" runat="server"><asp:Label ID="Label13" runat="server" Text="Call Duration" Font-Bold="True"></asp:Label><br /><br /><asp:GridView ID="GridView2" runat="server" AutoGenerateColumns="False" 
            CellPadding="4" ForeColor="#333333" GridLines="None" Width="100%"><AlternatingRowStyle BackColor="White" ForeColor="#284775" /><Columns><asp:TemplateField HeaderStyle-Width="200px" HeaderText="Provider"><ItemTemplate><asp:Label ID="Label4" runat="server" Text='<%# Bind("ID") %>' Visible=false></asp:Label><asp:Image ID="imgProvider" runat="server" AlternateText='<%# Eval("ID") %>'
                        ImageUrl='<%# "images/small/"+ Eval("ID") + ".png" %>' /></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderImageUrl="~/images/timehead.jpg"><ItemTemplate><div style="width: 380px; height: 18px; margin: 0 20px 0 20px; background-image: url('http://localhost:49460/promo/images/scale.gif');"><asp:Literal ID="Literal1" Text='<%# Bind("Graph") %>' runat="server"></asp:Literal></div></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderText="% of total usages" HeaderStyle-HorizontalAlign="Right" ItemStyle-HorizontalAlign="Right"><ItemTemplate><asp:Label ID="Label5" runat="server" Text='<%# Bind("Mins") %>'></asp:Label></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderText="Score" Visible="false"><ItemTemplate><asp:Label ID="Label6" runat="server" Text='<%# Bind("Score") %>'></asp:Label></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderText="" HeaderStyle-Width="10px"><ItemTemplate></ItemTemplate></asp:TemplateField></Columns><EditRowStyle BackColor="#999999" /><FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" /><HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" /><PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" /><RowStyle BackColor="#F7F6F3" ForeColor="#333333" /><SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" /><SortedAscendingCellStyle BackColor="#E9E7E2" /><SortedAscendingHeaderStyle BackColor="#506C8C" /><SortedDescendingCellStyle BackColor="#FFFDF8" /><SortedDescendingHeaderStyle BackColor="#6F8DAE" /></asp:GridView><br /><br /><br /><asp:Label ID="Label14" runat="server" Font-Bold="True" Text="Call Frequency"></asp:Label><br /><br /><asp:GridView ID="GridView5" runat="server" AutoGenerateColumns="False" 
            CellPadding="4" ForeColor="#333333" GridLines="None" Width="100%"><AlternatingRowStyle BackColor="White" ForeColor="#284775" /><Columns><asp:TemplateField HeaderStyle-Width="200px" HeaderText="Provider"><ItemTemplate><asp:Label ID="Label4" runat="server" Text='<%# Bind("ID") %>' Visible=false></asp:Label><asp:Image ID="imgProvider" runat="server" AlternateText='<%# Eval("ID") %>'
                        ImageUrl='<%# "images/small/"+ Eval("ID") + ".png" %>' /></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderImageUrl="~/images/timehead.jpg"><ItemTemplate><div style="width: 380px; height: 18px; margin: 0 20px 0 20px; background-image: url('http://localhost:49460/promo/images/scale.gif');"><asp:Literal ID="Literal1" Text='<%# Bind("Graph") %>' runat="server"></asp:Literal></div></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderText="% of total usages" HeaderStyle-HorizontalAlign="Right" ItemStyle-HorizontalAlign="Right"><ItemTemplate><asp:Label ID="Label21" runat="server" Text='<%# Bind("Mins") %>'></asp:Label></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderText="Score" Visible="false"><ItemTemplate><asp:Label ID="Label22" runat="server" Text='<%# Bind("Score") %>'></asp:Label></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderText="" HeaderStyle-Width="10px"><ItemTemplate></ItemTemplate></asp:TemplateField></Columns><EditRowStyle BackColor="#999999" /><FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" /><HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" /><PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" /><RowStyle BackColor="#F7F6F3" ForeColor="#333333" /><SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" /><SortedAscendingCellStyle BackColor="#E9E7E2" /><SortedAscendingHeaderStyle BackColor="#506C8C" /><SortedDescendingCellStyle BackColor="#FFFDF8" /><SortedDescendingHeaderStyle BackColor="#6F8DAE" /></asp:GridView><br /></asp:Panel></ContentTemplate>
        </asp:TabPanel>
        <asp:TabPanel runat="server" Width="100%"  HeaderText="Top 10 Numbers" ID="tabTop10">
        <ContentTemplate><asp:Panel ID="Panel3" runat="server"><asp:Label ID="Label15" runat="server" Text="Call Duration" Font-Bold="True"></asp:Label><br /><br /><asp:GridView ID="GridView3" runat="server" AutoGenerateColumns="False" 
            CellPadding="4" ForeColor="#333333" GridLines="None" Width="100%"><AlternatingRowStyle BackColor="White" ForeColor="#284775" /><Columns><asp:TemplateField HeaderStyle-Width="125px" HeaderText="Top 10 Numbers"><ItemTemplate><asp:Label ID="Label7" runat="server" Text='<%# Bind("ID") %>'></asp:Label></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderStyle-Width="70px" HeaderText=""><ItemTemplate><asp:Label ID="Label8" runat="server" Font-Size="9px"  Visible=false 
                            Text='<%# Bind("Provider") %>'> Font-Size=&quot;Small&quot; </asp:Label><asp:Image ID="imgProvider" runat="server" AlternateText='<%# Eval("Provider") %>'
                        ImageUrl='<%# "images/small/"+ Eval("Provider") + ".png" %>' /></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderImageUrl="~/images/timehead.jpg"><ItemTemplate><div style="width: 380px; height: 18px; margin: 0 20px 0 20px; background-image: url('http://localhost:49460/promo/images/scale.gif');"><asp:Literal ID="Literal1" Text='<%# Bind("Graph") %>' runat="server"></asp:Literal></div></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderText="% of total usages" HeaderStyle-HorizontalAlign="Right" ItemStyle-HorizontalAlign="Right"><ItemTemplate><asp:Label ID="Label9" runat="server" Text='<%# Bind("Mins") %>'></asp:Label></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderText="Score" Visible="false"><ItemTemplate><asp:Label ID="Label10" runat="server" Text='<%# Bind("Score") %>'></asp:Label></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderText="" HeaderStyle-Width="10px"><ItemTemplate></ItemTemplate></asp:TemplateField></Columns><EditRowStyle BackColor="#999999" /><FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" /><HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" /><PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" /><RowStyle BackColor="#F7F6F3" ForeColor="#333333" /><SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" /><SortedAscendingCellStyle BackColor="#E9E7E2" /><SortedAscendingHeaderStyle BackColor="#506C8C" /><SortedDescendingCellStyle BackColor="#FFFDF8" /><SortedDescendingHeaderStyle BackColor="#6F8DAE" /></asp:GridView><br /><br /><br /><asp:Label ID="Label16" runat="server" Font-Bold="True" Text="Call Frequency"></asp:Label><br /><br /><asp:GridView ID="GridView6" runat="server" AutoGenerateColumns="False" 
            CellPadding="4" ForeColor="#333333" GridLines="None" Width="100%"><AlternatingRowStyle BackColor="White" ForeColor="#284775" /><Columns><asp:TemplateField HeaderStyle-Width="125px" HeaderText="Top 10 Numbers"><ItemTemplate><asp:Label ID="Label23" runat="server" Text='<%# Bind("ID") %>'></asp:Label></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderStyle-Width="70px" HeaderText=""><ItemTemplate><asp:Label ID="Label24" runat="server" Font-Size="9px" Visible=false 
                            Text='<%# Bind("Provider") %>'> Font-Size=&quot;Small&quot; </asp:Label><asp:Image ID="imgProvider" runat="server" AlternateText='<%# Eval("Provider") %>'
                        ImageUrl='<%# "images/small/"+ Eval("Provider") + ".png" %>' /></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderImageUrl="~/images/timehead.jpg"><ItemTemplate><div style="width: 380px; height: 18px; margin: 0 20px 0 20px; background-image: url('http://localhost:49460/promo/images/scale.gif');"><asp:Literal ID="Literal1" Text='<%# Bind("Graph") %>' runat="server"></asp:Literal></div></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderText="% of total usages" HeaderStyle-HorizontalAlign="Right" ItemStyle-HorizontalAlign="Right"><ItemTemplate><asp:Label ID="Label25" runat="server" Text='<%# Bind("Mins") %>'></asp:Label></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderText="Score" Visible="false"><ItemTemplate><asp:Label ID="Label26" runat="server" Text='<%# Bind("Score") %>'></asp:Label></ItemTemplate></asp:TemplateField><asp:TemplateField HeaderText="" HeaderStyle-Width="10px"><ItemTemplate></ItemTemplate></asp:TemplateField></Columns><EditRowStyle BackColor="#999999" /><FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" /><HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" /><PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" /><RowStyle BackColor="#F7F6F3" ForeColor="#333333" /><SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" /><SortedAscendingCellStyle BackColor="#E9E7E2" /><SortedAscendingHeaderStyle BackColor="#506C8C" /><SortedDescendingCellStyle BackColor="#FFFDF8" /><SortedDescendingHeaderStyle BackColor="#6F8DAE" /></asp:GridView><br /></asp:Panel></ContentTemplate>
        </asp:TabPanel>
    </asp:TabContainer>

  
   
    <br />
    </asp:Content>

